package com.camtc.camcenter.enums;

import com.camtc.camcenter.exception.ErrorInfo;
import lombok.AllArgsConstructor;

/**
 * <p>
 * 错误信息实例
 * </p>
 *
 * @author chentianshun
 * @since 2021-06-22
 */

@AllArgsConstructor
public enum CustomErrorInfo implements ErrorInfo {
    /**
     * 系统消息
     */
    OK("200", "处理正常"),
    EXISTS("201", "数据已上传,请不要重复操作！"),
    UNSPECIFIED("999", "网络异常"),
    UNKNOW_ERROR("996", "系统或网络异常"),
    SYS_ERROR("998", "系统内部错误 - {}"),
    SYS_INVALID_REQUEST_PATH("857", "无效请求路径 - {}");

    private final String code;

    private final String description;

    @Override
    public String getCode() {
        return code;
    }

    @Override
    public String getDescription() {
        return description;
    }


}
